package com.jack.framework.test;

import com.jack.framework.cache.Cacheable;
import org.springframework.stereotype.Repository;

import java.util.ArrayList;
import java.util.List;

/**
 * Created by zhang_j on 2020/7/17
 */
@Repository
public class CacheRepository {

    private static int count = 0;

    @Cacheable(name = "cache", expireMills = 60*60)
    public List<Integer> get(Object o){
        List<Integer> list = new ArrayList<>();
        list.add(1);
        System.out.println(count++);
        return list;
    }
}
